package com.biubiu.biubiuexam.nosql.repository;

import com.biubiu.biubiuexam.nosql.model.ExamQuestion;
import org.springframework.data.mongodb.repository.MongoRepository;

import java.util.List;

/**
 * The interface Exam question repository.
 */
public interface ExamQuestionRepository extends MongoRepository<ExamQuestion, String> {

    /**
     * Find exam question by link exam question.
     *
     * @param link the link
     * @return the exam question
     */
    ExamQuestion findExamQuestionByLink(String link);

    /**
     * Find exam question all by teacher id list.
     *
     * @param teacherID the teacher id
     * @return the list
     */
    List<ExamQuestion> findExamQuestionAllByTeacherId(Long teacherID);

    long count();

}
